<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  ~ Copyright © 2013-2016 The Nxt Core Developers.                            ~
  ~ Copyright © 2016-2017 Jelurida IP B.V.                                    ~
  ~                                                                           ~
  ~ See the LICENSE.txt file at the top-level directory of this distribution  ~
  ~ for licensing information.                                                ~
  ~                                                                           ~
  ~ Unless otherwise agreed in a custom licensing agreement with Jelurida B.V.,
  ~ no part of the Nxt software, including this file, may be copied, modified,~
  ~ propagated, or distributed except according to the terms contained in the ~
  ~ LICENSE.txt file.                                                         ~
  ~                                                                           ~
  ~ Removal or modification of this copyright notice is prohibited.           ~
  ~                                                                           ~
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->

<div id="recipient_modal_template">
    <div class="form-group">
        <label for="{{name}}_recipient" data-i18n="recipient">RECIPIENT</label>
        <div id="{{name}}_account_id_reader" class="scan-qr-code-reader" style="display:none;margin:auto;width:384px;height:384px;"></div>
        <button type="button" data-reader="{{name}}_account_id_reader" data-result="{{name}}_recipient" class="scan-qr-code btn btn-default btn-xs">
            <i class="fa fa-qrcode"></i>
        </button>
        <div class="input-group">
            <input type="text" class="form-control" name="recipient" id="{{name}}_recipient" placeholder="Recipient Account" data-i18n="[placeholder]recipient_account" autofocus tabindex="1" />
            <span class="input-group-btn btn-group recipient_selector">
                <button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown"><span class="glyphicon glyphicon-user"></span></button>
                <!--suppress HtmlUnknownTag -->
                <ul class="dropdown-menu scrollable-menu" role="menu" style="right:0;left:auto;"></ul>
            </span>
        </div>
    </div>
    <div class="form-group recipient_public_key">
        <label for="{{name}}_recipient_public_key" data-i18n="recipient_public_key">Recipient Public Key</label>
        <input type="text" class="form-control" name="recipientPublicKey" id="{{name}}_recipient_public_key" placeholder="Public Key" data-i18n="[placeholder]public_key" tabindex="2" spellcheck="false" />
    </div>
</div>


<div id="add_message_modal_template">
    <div class="form-group add_message_container">
        <input type="checkbox" name="add_message" id="{{name}}_add_message" class="add_message" tabindex="101" /> <label for="{{name}}_add_message" style="font-weight:normal;margin-bottom:0;"> <span data-i18n="add_message_q">Add a Message?</span></label>
    </div>
    <div class="form-group optional_message">
        <label for="{{name}}_message" data-i18n="message">MESSAGE</label>
        <textarea class="form-control" id="{{name}}_message" name="message" rows="4" tabindex="102"></textarea>
        <div style="margin-top:3px" id="{{name}}_to_specific_account_message_options">
            <label for="{{name}}_encrypt_message" style="font-weight:normal;color:#666"><input type="checkbox" name="encrypt_message" id="{{name}}_encrypt_message" value="1" data-default="checked" checked="checked" /> <span data-i18n="encrypt_message">Encrypt Message</span></label>
        </div>
        <div style="margin-top:3px;display:none" id="{{name}}_to_anyone_message_options">
            <label for="{{name}}_encrypt_message" style="font-weight:normal;color:#666" data-i18n="message_is_not_encrypted">This message is not encrypted.</label>
        </div>
        <div style="margin-top:3px">
            <label for="{{name}}_message_permanent" style="font-weight:normal;color:#666"><input type="checkbox" name="permanent_message" id="{{name}}_message_permanent" value="1" data-default="unchecked" /> <span data-i18n="permanent_message">Message is Never Deleted</span></label>
        </div>
    </div>
</div>


<div id="add_public_message_modal_template">
    <div class="form-group add_message_container">
        <input type="checkbox" name="add_message" id="{{name}}_add_public_message" class="add_message" tabindex="101" /> <label for="{{name}}_add_public_message" style="font-weight:normal;margin-bottom:0;"> <span data-i18n="add_message_q">Add a Message?</span></label>
    </div>
    <div class="form-group optional_message">
        <label for="{{name}}_public_message" data-i18n="message">MESSAGE</label>
        <textarea class="form-control" id="{{name}}_public_message" name="message" rows="4" tabindex="102"></textarea>
    </div>
</div>

<div id="secret_phrase_modal_template">
    <div class="form-group secret_phrase">
        <label for="{{name}}_password" data-i18n="passphrase">PASSPHRASE</label>
        <div id="{{name}}_secret_phrase_reader" class="scan-qr-code-reader" style="display:none;margin:auto;width:384px;height:384px;"></div>
        <button id="{{name}}_secret_phrase_scan" type="button" data-reader="{{name}}_secret_phrase_reader" data-result="{{name}}_password" class="scan-qr-code btn btn-default btn-xs ">
            <i class="fa fa-qrcode"></i>
        </button>
        <input type="password" name="secretPhrase" id="{{name}}_password" class="form-control" placeholder="" tabindex="111">
    </div>
</div>

<div id="admin_password_modal_template">
    <div class="form-group">
        <label for="{{name}}_admin_password" data-i18n="admin_password">ADMIN PASSWORD</label>
        <input type="password" name="adminPassword" id="{{name}}_admin_password" class="form-control" placeholder="" tabindex="112">
    </div>
</div>

<div id="fee_calculation_modal_template">
    <div class="row">
        <div class="col-xs-12 col-sm-6 col-md-6">
            <div class="form-group">
                <label for="{{name}}_fee" data-i18n="fee">FEE</label>
                <button type="button" class="btn btn-default btn-xs btn-calculate-fee" data-loading-text="Calculating..." data-i18n="[data-loading-text]calculating"><span data-i18n="calculate">CALCULATE</span><span class="warning-label" id="{{name}}_recalc"> *</span></button>
                <div class="input-group">
                    <input type="number" name="feeNXT" id="{{name}}_fee" class="form-control" step="any" placeholder="Minimum Fee" data-i18n="[placeholder]minimum_fee" tabindex="100">
                    <span class="input-group-addon">NXT</span>
                </div>
            </div>
        </div>
    </div>
</div>

<div id="advanced_deadline_template">
    <div class="row advanced">
        <div class="col-xs-6 col-sm-6 col-md-6">
            <div class="form-group">
                <label for="{{name}}_deadline" data-i18n="deadline_hours">DEADLINE (HOURS)</label>
                <input type="number" name="deadline" id="{{name}}_deadline" class="form-control" placeholder="Deadline" data-i18n="[placeholder]deadline" min="1" data-default="24" value="24" tabindex="122">
            </div>
        </div>
    </div>
</div>


<div id="advanced_approve_template">
    <div class="advanced_mandatory_approval" id="{{name}}_mandatory_approval" style="display:none;">
        <div class="row">
            <div class="col-xs-6">
                <div class="form-group mandatory_approval_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
            </div>
            <div class="col-xs-6">
                <div class="phasing_only_enabled_info">
                    <span data-i18n="mandatory_approval_enabled_info">Mandatory Approval account control is enabled. Please set Finish Height.</span><br/>

                    <a href="#" data-toggle="modal" data-target="#account_details_modal" data-i18n="mandatory_approval_details" data-detailstab="account_control">Account Control Details</a>
                </div>
            </div>
        </div>
    </div>

    <div class="advanced approve_modal" id="{{name}}_approve_modal">

        <div class="phasing_safe_alert alert alert-warning" role="alert" style="margin-left:0;display:none;">
            <span style="font-weight:bold;" data-i18n="warning">Warning</span>!
            <span data-i18n="transaction_type_not_phasing_safe">Transaction type not safe for phasing/approval.</span>
        </div>
        <div role="tabpanel" class="approve_tab_panel">
            <!-- Nav tabs -->
            <ul class="nav nav-tabs approve_tab_list" role="tablist">
                <li role="presentation" class="active show_popover" data-toggle="popover" data-delay="250" data-placement="top" data-content="Transaction does not need further approval to become valid" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_no_approval_tab_help">
                    <a href="#{{name}}_approve_tab_no_approval" aria-controls="{{name}}_approve_tab_no_approval" class="at_no_approval" role="tab" data-toggle="tab"><span class="label label-default"><i class="ion-close-circled"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction execution is delayed, transaction does not need further approval to become valid" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_phased_no_approval_tab_help">
                    <a href="#{{name}}_approve_tab_phased_no_approval" aria-controls="{{name}}_approve_tab_phased_no_approval" class="at_no_approval" role="tab" data-toggle="tab"><span class="label label-warning"><i class="ion-load-a"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction has to be approved by a certain number of accounts" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_by_account_tab_help">
                    <a href="#{{name}}_approve_tab_accounts" aria-controls="{{name}}_approve_tab_accounts" class="at_accounts" role="tab" data-toggle="tab"><span class="label label-warning"><i class="fa fa-group"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction has to be approved by accounts holding a certain amount of NXT" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_by_balance_tab_help">
                    <a href="#{{name}}_approve_tab_balance" aria-controls="{{name}}_approve_tab_balance" class="at_balance" role="tab" data-toggle="tab"><span class="label label-warning"><i class="fa fa-money"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction has to be approved by asset holders with a certain stake" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_by_asset_tab_help">
                    <a href="#{{name}}_approve_tab_asset_holders" aria-controls="{{name}}_approve_tab_asset_holders" class="at_asset_holders" role="tab" data-toggle="tab"><span class="label label-warning"><i class="fa fa-signal"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction has to be approved by currency holders with a certain stake" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_by_currency_tab_help">
                    <a href="#{{name}}_approve_tab_currency_holders" aria-controls="{{name}}_approve_tab_currency_holders" class="at_currency_holders" role="tab" data-toggle="tab"><span class="label label-warning"><i class="fa fa-bank"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction is approved by the inclusion of the specified transaction hash in the blockchain" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_by_transaction_tab_help">
                    <a href="#{{name}}_approve_tab_transaction" aria-controls="{{name}}_approve_tab_transaction" class="at_transaction" role="tab" data-toggle="tab"><span class="label label-warning"><i class="fa fa-thumbs-up"></i></span></a>
                </li>
                <li role="presentation" class="show_popover" data-toggle="popover" data-placement="top" data-content="Transaction is approved by revealing a hashed secret message" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_modal_by_hash_tab_help">
                    <a href="#{{name}}_approve_tab_hash" aria-controls="{{name}}_approve_tab_hash" class="at_hash" role="tab" data-toggle="tab"><span class="label label-warning"><i class="fa fa-question"></i></span></a>
                </li>
            </ul>

            <!-- Tab panes -->
            <div class="tab-content">
                <div role="tabpanel" class="tab-pane tab_pane_approve active" id="{{name}}_approve_tab_no_approval">
                    <span data-i18n="process_without_approval">Process without approval.</span>
                    <input type="hidden" name="phased" value="false" />
                </div>

                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_phased_no_approval">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="-1" disabled />
                    <input type="hidden" name="phasingQuorum" value="0" disabled />
                    <input type="hidden" name="phasingMinBalanceModel" value="0" disabled />
                </div>

                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_accounts">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group phasing_number_accounts_group">
                                <label data-i18n="approve_number_accounts">Number Accounts</label>
                                <i class="fa fa-question-circle modal-context-help" data-content="" data-toggle="popover" data-trigger="hover" data-container="#{{name}}_approve_modal" data-i18n="[data-content]approve_transaction_amount_help"></i>
                                <input name="phasingQuorum" type="number" min="1" class="form-control" disabled />
                            </div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="form-group add_approval_whitelist_group" data-modal-ui-element="multi_accounts_modal_ui_element"></div>
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_min_balance_model_group approve_mb_accounts" data-modal-ui-element="min_balance_model_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group approve_mb_model_1 approve_min_balance_nxt" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                            <div class="form-group approve_mb_model_2 approve_min_balance_asset_quantity" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                            <div class="form-group approve_mb_model_3 approve_min_balance_currency_units" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-xs-12">
                            <div class="form-group approve_holding_asset_optional approve_mb_model_2" data-modal-ui-element="add_asset_modal_ui_element"></div>
                            <div class="form-group approve_holding_currency_optional approve_mb_model_3" data-modal-ui-element="add_currency_modal_ui_element"></div>
                        </div>
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="0" disabled />
                </div>

                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_balance">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_transaction_amount_nxt" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="form-group add_approval_whitelist_group" data-modal-ui-element="multi_accounts_modal_ui_element"></div>
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_min_balance_model_group approve_mb_balance" data-modal-ui-element="min_balance_model_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group approve_mb_model_1 approve_min_balance_nxt" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="1" disabled />
                </div>

                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_asset_holders">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_transaction_asset_quantity" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-xs-12">
                            <div class="form-group approve_holding_asset" data-modal-ui-element="add_asset_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="form-group add_approval_whitelist_group" data-modal-ui-element="multi_accounts_modal_ui_element"></div>
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_min_balance_model_group approve_mb_asset" data-modal-ui-element="min_balance_model_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group approve_mb_model_2 approve_min_balance_asset_quantity" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="2" disabled />
                </div>

                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_currency_holders">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_transaction_currency_units" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-xs-12">
                            <div class="form-group approve_holding_currency" data-modal-ui-element="add_currency_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="form-group add_approval_whitelist_group" data-modal-ui-element="multi_accounts_modal_ui_element"></div>
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group approve_min_balance_model_group approve_mb_currency" data-modal-ui-element="min_balance_model_modal_ui_element"></div>
                        </div>
                        <div class="col-xs-6">
                            <div class="form-group approve_mb_model_3 approve_min_balance_currency_units" data-modal-ui-element="simple_input_with_addon_modal_ui_element"></div>
                        </div>
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="3" disabled />
                </div>
                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_transaction">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="form-group advanced">
                        <label for="approved_by_transaction_hash" data-i18n="approved_by_transaction_hash">APPROVED BY TRANSACTION HASH</label>
                        <input type="text" class="form-control" name="phasingLinkedFullHash" id="approved_by_transaction_hash" placeholder="Approved By Transaction Full Hash" data-i18n="[placeholder]approved_by_transaction_full_hash" spellcheck="false" />
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="4" disabled />
                    <input type="hidden" name="phasingQuorum" value="1" disabled />
                    <input type="hidden" name="phasingMinBalanceModel" value="0" disabled />
                </div>
                <div role="tabpanel" class="tab-pane tab_pane_approve" id="{{name}}_approve_tab_hash">
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group phasing_finish_height_group" data-modal-ui-element="block_height_modal_ui_element"></div>
                        </div>
                    </div>
                    <div class="form-group advanced">
                        <label for="approved_by_hashed_secret" data-i18n="approved_by_hashed_secret">APPROVED BY HASHED SECRET</label>
                        <input type="text" class="form-control" name="phasingHashedSecret" id="approved_by_hashed_secret" placeholder="Hashed Secret" data-i18n="[placeholder]approved_by_hashed_secret_placeholder" spellcheck="false" />
                    </div>
                    <div class="row">
                        <div class="col-xs-6">
                            <div class="form-group hash_algorithm_model_group" data-modal-ui-element="hash_algorithm_model_modal_ui_element"></div>
                        </div>
                    </div>
                    <input type="hidden" name="phased" value="true" disabled />
                    <input type="hidden" name="phasingVotingModel" value="5" disabled />
                    <input type="hidden" name="phasingQuorum" value="1" disabled />
                    <input type="hidden" name="phasingMinBalanceModel" value="0" disabled />
                </div>
            </div>
        </div>
    </div>
</div>


<div id="advanced_rt_hash_template">
    <div class="form-group advanced">
        <label for="{{name}}_referenced_transaction" data-i18n="referenced_transaction_hash">REFERENCED TRANSACTION HASH</label>
        <input type="text" class="form-control" name="referencedTransactionFullHash" id="{{name}}_referenced_transaction" placeholder="Referenced Transaction Full Hash" data-i18n="[placeholder]referenced_transaction_full_hash" tabindex="131" spellcheck="false" />
    </div>
</div>


<div id="advanced_broadcast_template">
    <div class="form-group advanced" style="margin-bottom:0;">
        <input type="checkbox" name="doNotBroadcast" id="{{name}}_do_not_broadcast" class="do_not_broadcast" value="1" tabindex="141"/> <label for="{{name}}_do_not_broadcast" style="font-weight:normal;" data-i18n="do_not_broadcast">Do Not Broadcast</label>
        <div class="form-group advanced optional_do_not_sign">
            <input type="checkbox" name="doNotSign" id="{{name}}_do_not_sign" class="do_not_sign" value="1" tabindex="142"/> <label for="{{name}}_do_not_sign" style="font-weight:normal;" data-i18n="do_not_sign">DO NOT SIGN</label>
        </div>
        <div class="form-group advanced optional_public_key">
            <label data-i18n="public_key">PUBLIC KEY</label>
            <div class="form-group">
                <textarea class="form-control" name="publicKey" rows="1"></textarea>
            </div>
        </div>
    </div>
</div>


<div id="advanced_note_to_self_template">
    <div class="form-group advanced">
        <input type="checkbox" name="add_note_to_self" id="{{name}}_add_note_to_self" class="add_note_to_self" tabindex="151" /> <label for="{{name}}_add_note_to_self" style="font-weight:normal;margin-bottom:0;"> <span data-i18n="add_note_to_self">Add Note to Self?</span></label>
    </div>
    <div class="form-group advanced optional_note">
        <label for="{{name}}_note_to_self" data-i18n="note_to_self">Note to Self</label>
        <textarea class="form-control" id="{{name}}_note_to_self" name="note_to_self" rows="4" tabindex="152"></textarea>
        <div style="margin-top:3px;">
            <label style="font-weight:normal;color:#666" data-i18n="note_is_encrypted">This note is encrypted.</label>
        </div>
    </div>
</div>
